package com.itany.shop.service;

import com.itany.shop.exception.LoginDisabledException;
import com.itany.shop.exception.RequestParameterErrorException;
import com.itany.shop.vo.Cart;

/**
 * @Author:石小俊
 * @Date:2022/12/16 11:28
 * @Version:1.0-SNAPSHOT
 * @Description:
 */
public interface CartService {

    /**
     * 加入购物车
     * @param cart
     * @param id
     */
    public void addCart(Cart cart,String id) throws LoginDisabledException, RequestParameterErrorException;

    /**
     * 修改购物车中指定明细的数量
     * @param cart
     * @param id
     * @param num
     */
    public void modifyCart(Cart cart,String id,String num) throws LoginDisabledException, RequestParameterErrorException;

    /**
     * 删除指定的明细
     * @param cart
     * @param id
     */
    public void removeCart(Cart cart,String id) throws LoginDisabledException, RequestParameterErrorException;
}
